Virtual machines are code that performs the logic of an operating system and potentially a set of one or more applications as well. However, instead of such logic being performed on a client computing system (the “client”) that actually renders the associated user interface, the virtual machine executes on a host computing system (the “host”).
In operation, the virtual machine generates images and/or rendering instructions representing the user interface (such as a desktop or application user interface) to be rendered on the client, and causes the host to transmit the same to the client. The client receives the image and/or rendering instructions, and renders the user interface accordingly. The client also receives user input and transmits the same to the host. The virtual machine processes the input and changes the virtual machine state. If such change in state causes a change to the user interface, the changes are transmitted to the client for further rendering. This process repeats rather quickly, and the response time is sufficiently fast, that the user of the client might not be even able to distinguish whether the operating system and perhaps the associated applications are operated on the client or via virtual machine.
A host is capable of running a number of virtual machines. The host typically ensures isolation between the virtual machines. Thus, a single host may provide the operating system logic for a number of remote clients. Each host has a hypervisor that uses underlying physical resources (such as network bandwidth, storage, memory, processing) to provide the appearance to the virtual machine as though the virtual machine has dedicated physical resources. This appearance is referred to as a virtual resource. Thus, each virtual machine may have virtual hard drivers, virtual processors, virtual network bandwidth, virtual RAM and so forth.
In order to provision a virtual machine, the hypervisor should have access to all of the operating system files (and optionally application files if the virtual machine has such applications) necessary for the operating system (and optionally the applications) to run. Rather than physically copy all of these operating system files every time a virtual machine is to be provisioned, the arraying subsystem of the tenant store that the host has access to is used to virtually copy the operating system.
For instance, a master container includes a virtual machine template that contains all of the operating system files, and virtual machine configuration data (for the operating system, and also defining the characteristics of the various virtual devices that the virtual machine is to have). In order to perform the virtual copying, an associated container is created, which has a pointer to the actual content of the master container. The arraying subsystem offers up an instance of the virtual machine container to the hypervisor for each virtual machine to be provisioned following the template of the master container. The hypervisor uses the virtual hardware configuration information to set up virtual hardware for the virtual machine, and the operating system files pointed to by the associated container are used to instantiate the virtual machine. The operating system files in the template may be such that the operating system is pre-configured in a particular way. However, in a customization phase, the virtual machine may be further configured by changing settings through the running virtual machine itself. The virtual container stays associated with the virtual machine until the virtual machine is terminated.
There is a limit to the number of virtual containers that may be virtually copied from a master container. Accordingly, there is a limit to the number of virtual machines that may be running at the same time that each are associated with a distinct virtual containers virtually copied from the same master container.